﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<dynamic>" %>
<%
    for (int i = 0; i < Model.Count; i++)
    {
        Response.Write(Html.Action("ViewAuction", new { auction=Model[i] }));
    }
    if (Model.Count>0)
        Response.Write("<input type='hidden' name='lastId' id='lastId' value='" + Model[Model.Count - 1].AuctionId.ToString() + "'  />"); 
    else
        Response.Write("<input type='hidden' name='lastId' id='lastId' value='-1'  />"); 
     %>